package ebj.common.java8.base;

import java.util.Map;

import com.google.common.collect.Maps;

public class Test {
    public static void main(String[] args) {
        Person p1 = new Person();
        p1.setAge(18);
        p1.setGender('0');
        p1.setName("Ali");
        Person p2 = new Person();
        p2.setAge(18);
        p2.setGender('0');
        p2.setName("Ali");
        
        System.out.println("p1.equals(p2): " + p2.equals(p1));
        System.out.println(p1);
        System.out.println(p2);
        
        Map<Person, Integer> map = Maps.newHashMap();
        map.put(p1, 10);
        map.put(p2, 20);
        System.out.println("result: " + ('a' == 'a'));
        System.out.println(map.get(new Person("Ali", 18, '0')));
    }
}
